<template>
	<view>
		<view class="yuyue_number">
			<text class="decal">{{peoples}}</text>
			<text>预约中数量</text>
		</view>
		<view class="manger_wrapper">
			<manager_item @managerItemClick="itemClick" v-for="(item,index) in manager_items" :key="item.label" :managerItem="item"></manager_item>
		</view>
	</view>
</template>

<script>
	import manager_item from '@/components/manager_item.vue'
	import { getPeoplesNum } from '@/request/api/manager_index.js'
	export default {
		name: 'manager_index',
		components: {
			manager_item
		},
		data() {
			return {
				peoples: 0,
				manager_items: [
					{
						img: '../../../static/manage1.png',
						label: '订单管理',
						url: 'manage_order'
					},
					{
						img: '../../../static/manage2.png',
						label: '上架核实',
						url: 'uploadStatus'
					},
					{
						img: '../../../static/manage23.png',
						label: '提现审核',
						url: 'withDrawStatus'
					},
					{
						img: '../../../static/manage23.png',
						label: '兑换数字资产审核',
						url: 'coinReview'
					},
					{
						img: '../../../static/manage4.png',
						label: '记账统计',
						url: 'shopTotal'
					},
					{
						img: '../../../static/manage5.png',
						label: '红木管理',
						url: 'shopManage'
					},
					{
						img: '../../../static/manage6.png',
						label: '转移确认',
						url: 'shift'
					},
					{
						img: '../../../static/manage7.png',
						label: '上架兑换管理',
						url: 'upframeExchange'
					},
					{
						img: '../../../static/manage8.png',
						label: '上架提货管理',
						url: 'upframeWithdraw'
					},
					{
						img: '../../../static/manage9.png',
						label: '设置编号',
						url: 'setNumber'
					},
					{
						img: '../../../static/manage10.png',
						label: '预约管理',
						url: 'apply'
					},
					{
						img: '../../../static/manage11.png',
						label: '预约统计',
						url: 'apply_team'
					}
				]
			}
		},
		methods: {
			itemClick(item) {
				uni.navigateTo({
					url: item.url
				})
			}
		},
		onLoad() {
			getPeoplesNum().then((res)=>{
				this.peoples = res.data
			})
		}
	}
</script>

<style>
	.yuyue_number{
	    height: 77px;
	    background: #fff;
		display: flex;
		flex-direction: column;
		justify-content: center;
		align-items: center;
	}
	
	.yuyue_number .decal{
		color: #fc4141;
	}
	.yuyue_number text{
		font-size:17px;
	}
	.manger_wrapper{
		display: flex;
		flex-direction: column;
		background-color: #fff;
		margin-top: 10px;
		padding: 0 20px;
	}
	.wrapper_item{
	    margin-bottom: 10px;
	    box-shadow: 0 0 10px hsla(0,0%,78.4%,.5);
	    padding: 0 10px;
	    height: 53px;
	    border-bottom: 1px solid #eee;
		display: flex;
		flex-direction:row;
	    align-items: center;
	}




</style>